package c.main.web;

import c.main.core.C;
import c.main.core.WcsLoader;
import org.apache.log4j.Logger;

import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.annotation.WebListener;


/**
 * Author: chengwei
 * Date:   2016/3/15
 * Time:   14:15
 */
@WebListener
public class WebCoreListener implements ServletContextListener{
    protected Logger log = Logger.getLogger(WcsLoader.class);
    
    @Override
    public void contextInitialized(ServletContextEvent servletContextEvent) {
        log.info("系统开始加载...");
        WcsLoader loader = new WcsLoader();
        loader.load();
        
        log.info("系统加载完成...");
    }

    @Override
    public void contextDestroyed(ServletContextEvent servletContextEvent) {
    }
}
